Range

Function

This API is used to get parameter range for Storage > Schedules(cloud dedicated) > Capture page.

Note:

The Range provides reference information for client UI input limits and API request limits. When sending Get and Set requests, the parameters must be strictly limited according to the Range, otherwise the request may be rejected by the device.

Request Message

None.

Sample:

POST /API/Schedules/Capture/Range HTTP/1.1
{
    "version": "1.0",
    "data": {}
}

Response Message

Parameter Description

Table 1

ParameterRangeTypeDescription
channelCH1
CH1x
IP_CH1
IP_CH1x
WIFI_CH1
WIFI_CH1x
The number of channels depends on the functionality of the device
string
array
Each array bit represents a channel with a string
channel_infoJSON ObjectChannel Info object,see Table 2 for detailed information
channel_maxintTotal channel of the current device
support_copyboolPage support copy (NVR, DVR dedicated)

Table 2

Channel Info object

ParameterRangeTypeDescription
CH1Json ObjectChannel object,see Table 3 for detailed information
WIFI_CH1Json Object

Table 3

Channel object

ParameterRangeTypeDescription
status"Offline","Online",
“Nonsupport”
stringChannel online status, only for digital channels.
Note: This field does not exist when the channel is online
copy_ch"digit", "analog", "wifi", "local", "all"stringSupport channel replication logo (NVR, DVR special)
categoryarraysee Table 4 for detailed information

Table 4

ParameterRangeTypeDescription
schedule_type"Normal","Motion","Io"stringSupported schedule types
schedule_listarraysee Table 5 for detailed information

Table 5

ParameterRangeTypeDescription
enableboolWhether the schedule is enabled
start_time0~1439intstart time
end_time0~1440intend time
weekday"Sunday",
"Monday",
"Tuesday",
"Wednesday",
"Thursday",
"Friday",
"Saturday"
stringnumber of days

Tips:

The response message of the Range request may not contain all the fields in the above table, and the fields not included indicate that the device does not support this parameter configuration.

Sample:

HTTP/1.1 200 OK
Content-Type: application/json
{
    "result": "success",
    "data": {
        "channel_max": 1,
        "support_copy": true,
        "channel_info": {
            "type": "object",
            "items": {"CH1": {
                "type": "object",
                "items": {
                    "status": {
                        "description": "Only offline channel has this variable.",
                        "type": "string",
                        "mode": "r",
                        "items": [
                            "Offline",
                            "Online"
                        ]
                    },
                    "copy_ch": {
                        "type": "string",
                        "items": ["all"]
                    },
                    "category": {
                        "type": "array",
                        "min_size": 0,
                        "max_size": 5,
                        "items": [{
                            "schedule_type": {
                                "type": "string",
                                "items": [
                                    "Normal",
                                    "Motion"
                                ]
                            },
                            "schedule_list": {
                                "type": "array",
                                "min_size": 0,
                                "max_size": 8,
                                "items": [{
                                    "enable": {"type": "bool"},
                                    "start_time": {
                                        "type": "int32",
                                        "min": 0,
                                        "max": 1439
                                    },
                                    "end_time": {
                                        "type": "int32",
                                        "min": 0,
                                        "max": 1440
                                    },
                                    "weekday": {
                                        "type": "array",
                                        "min_size": 1,
                                        "max_size": 7,
                                        "items": [{
                                            "type": "string",
                                            "items": [
                                                "Sunday",
                                                "Monday",
                                                "Tuesday",
                                                "Wednesday",
                                                "Thursday",
                                                "Friday",
                                                "Saturday"
                                            ]
                                        }]
                                    }
                                }]
                            }
                        }]
                    }
                }
            }}
        }
    }
}

Error Code

See Response Messages Body and Common error_code for more information.